<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script type="text/javascript">
					
					try{
						// 将可能出现异常的代码放在try-catch
						console.log(document.forms.input.length);
					}catch(exception)
					{
						alert("捕获异常")
					}finally
					{
						console.log("finally");
					}
					
					console.log("脚本正常结束");
				</script>
	</body>
</html>
